home *** CD-ROM | disk | FTP | other *** search
/ Screen Candy / Screen Candy Volume 1.iso / pc / install.dat < prev    next >
Text File  |  1994-04-21  |  9KB  |  283 lines

  1. /*
  2.  INSTALL.DAT
  3.  
  4.  Project: Screen Candy
  5.  Version: 1.0
  6.  
  7. */
  8.  
  9. /*  The @DefineProject block starts the installation script by telling
  10.     Install what version, product, and other basic information that
  11.     Install will need to process the installation.  The text that
  12.     @Name is set to is the same information that can be found on the
  13.     first line of the DISK.ID file.  Likewise the text that @Version
  14.     is set to, is the same information that can be found on the second
  15.     line of the DISK.ID file.  This information remains constant
  16.     throughout the entire distribution set.  @Subdir and @OutDrive are
  17.     used to define the default drive and directory for the target system
  18.     during the installation process.  
  19. */
  20.     
  21. @DefineProject
  22.     @Name = "Screen Candy"
  23.     @Version = "1.0"
  24.     @Subdir = "\\QTW"
  25.     @OutDrive = C
  26.     
  27. @EndProject
  28.  
  29. /*  The following @DefineVars block is used to assign variables to
  30.     specific types (Integer, QString, Drive, & Dir) as well as establishing
  31.     default values for the variables.  Later in this script file these 
  32.     variables are assigned values depending whether    particular files will be 
  33.     installed or not.
  34. */
  35.  
  36. @DefineVars
  37.     @Integer @amid       = 600
  38.     @Integer @qtw       = 1500
  39.     @Integer @TSIZE      = @Eval(@amid+@qtw)
  40.     @Integer @Red        = @RGB(255,0,0)             //DEFINE COLOR RED
  41.     @Integer @Green      = @RGB(0,255,0)             //DEFINE COLOR GREEN
  42.     @Integer @Blue       = @RGB(0,0,255)             //DEFINE COLOR BLUE
  43.     @Integer @Black      = @RGB(0,0,0)               //DEFINE COLOR BLACK
  44.     @Qstring @FileName  = "@StartupDrive:@StartupDir\\sc100\\scandy1.mov"
  45.     @Qstring @Directory  = "@StartupDrive:@StartupDir\\sc100"
  46.  
  47. @EndVars
  48.  
  49. @BackgroundMode(3,@Blue,@Black)
  50.  
  51. /* 
  52.     The following section displays the welcoming message during installation.
  53.  
  54. */
  55.  
  56.  
  57. @Display
  58.                 
  59.  
  60. This program installs the Screen Candy Screen Saver utility 
  61. on your hard drive.  To continue, choose "OK".  To quit choose
  62. "Cancel".  
  63.  
  64.  
  65. @Pause
  66. @Enddisplay
  67.  
  68. @SetOption(1001)  
  69. @SetOption(1002)
  70.  
  71. LOOP:
  72. @BackgroundMode(3,@Blue,@Black) //set background to blue/black
  73.  
  74.  
  75. @DlgCtrlSize(0,7,5,14,50)  // set coordinates & size of list box
  76. @GetOption @Checkbox @Prompt = "Select files to install"
  77.  @Name by default will install the program files to the Windows directory,
  78.  and Quicktime for Windows to a selected target directory.
  79. The total installation takes approximately 2.1 Mb of disk space.
  80.  
  81. @Option 1001 = "Screen Candy"
  82. @Option 1002 = "Quicktime for Windows        "
  83.  
  84. @EndOption
  85.  
  86.  
  87.  
  88. @if(1002 [= @option)
  89. NEWDRIVE:  // Goto label for reselecting drive
  90. /*
  91.     INSTALL will now prompt the end-user for the
  92.     drive they wish Screen Candy to be installed onto.
  93. */
  94. @BackgroundMode(3,@Blue,@Black)
  95.  
  96.  
  97. @DlgCtrlSize(0,8,15,15,27)
  98. @GetOutDrive @OutDrive @Prompt = "Enter target drive"
  99. @Suppress(0,17) // Suppress floppies & CD-ROM drives
  100. Please select the drive where you wish QuickTime 
  101. for Windows to be installed on your machine.  Any 
  102. available drive can be used assuming you have
  103. access rights to the drive you select, and
  104. there is enough space available for installation.
  105. @EndOutDrive
  106.  
  107.  
  108.  
  109. /*
  110.     INSTALL will now prompt the end-user for the
  111.     directory they wish Quicktime to be installed
  112.     into.
  113. */
  114.  
  115. NEWDIR:
  116. @BackgroundMode(3,@Blue,@Black)
  117.  
  118.  
  119. @DlgCtrlSize(0,7,0,8,35)
  120. @GetSubdir @Subdir @Prompt = "Enter target directory"
  121. Please select the directory
  122. you wish Quicktime to be installed under.
  123.  
  124. @EndSubdir
  125.  
  126. @EndIf
  127.  
  128.  
  129.  
  130.  
  131. @if(1001 [! @option) @amid=0 @Else @amid = 600 @EndIf //if group not selected zero out
  132. @if(1002 [! @option) @qtw=0 @Else @qtw = 1500  @EndIf //if group not selected zero out
  133.  
  134.  
  135. @TSIZE = @Eval((@amid+@qtw))   // add selected options' size requirements
  136.  
  137. // if total size > free space, then display
  138. // blue background and set default to loop back and select again.
  139. @If(@TSIZE*1024 > @DiskFree(@OutDrive))
  140.     @BackgroundMode(3,@Blue,@Black)
  141.     @Display
  142.         The drive you have selected does not have
  143.         enough free space available.
  144.         
  145.     @Pause
  146.     @EndDisplay
  147.     @GOTO NEWDRIVE
  148. @EndIf    
  149.  
  150. @BackgroundMode(3,@Blue,@Black)
  151. @SetOption(1600) @ClearOption(1700)
  152.  
  153.  
  154. @DlgCtrlSize(0,13,12,17,40)
  155. @GetOption @Prompt = "Selected files summary"
  156. You have selected to install the following options.
  157.                @if(1001 [= @option) Screen Candy            @amid K @Else Screen Candy         WILL NOT BE INSTALLED @EndIf
  158.                @if(1002 [= @option) Quicktime for Windows   @qtw K @Else Quicktime for Windows  WILL NOT BE INSTALLED @EndIf
  159.           
  160.                The selected files will require a total of:        @TSIZE K bytes.
  161.                The drive currently selected for installation has: @Eval(@DiskFree(@OutDrive)/1K) K free.
  162.  
  163.  
  164.  You may:
  165. @Option 1600 = "CONTINUE"
  166. @Option 1700 = "RESELECT OPTIONS"
  167. @EndOption
  168.  
  169.  
  170. @If(1700 [= @Option) @GOTO Loop @EndIf
  171.  
  172. @If(1001 [= @Option)
  173.     @SetINI("Screen Saver.Screen Candy", "MovieFileName", "@FileName" ,"control.ini")
  174.     @SetINI("Screen Saver.Screen Candy", "Directory", "@Directory" ,"control.ini")
  175.     @SetINI("Screen Saver.Screen Candy", "Option", "1" ,"control.ini")
  176.  
  177. @EndIf
  178. /*
  179.       The @DefineDisk blocks actually do the copying of the files, from the 
  180.       floppy disk to the hard disk of the end-users particular choice.
  181. */
  182.  
  183. @DefineDisk
  184.     @Label = "Screen Candy"
  185.  
  186. /*
  187.     The following files are not in a library and are always installed.
  188. */
  189. /*        @File  README.txt   @OUT *.*            */
  190.  
  191.     @If(1001 [= @Option)    // if install source selected, install
  192.         
  193.         @File qtw\Scandy.scr     @OUT @WindowsDrive:@WindowsDir\*.* @ASKOVERWRITE
  194.         @File qtw\VBRUN300.DLL     @OUT @WindowsDrive:@WindowsDir\*.* @ASKOVERWRITE
  195.         @File qtw\THREED.VBX     @OUT @WindowsDrive:@WindowsDir\*.* @ASKOVERWRITE
  196.         @File qtw\MANUAL.TXT     @OUT @WindowsDrive:@WindowsDir\*.* @ASKOVERWRITE
  197.  
  198.     @EndIf // Option 1001
  199.  
  200.     @If(1002 [= @Option)   // if install source selected, install
  201.  
  202.         @File qtw\qtmovie.vbx    @OUT @WindowsDrive:@WindowsDir\*.* @ASKOVERWRITE
  203.         @File qtw\qtpic.vbx    @OUT @WindowsDrive:@WindowsDir\*.* @ASKOVERWRITE
  204.         @File qtw\mciqtenu.dll    @out BIN\*.* @OVERWRITE
  205.         @File qtw\playenu.dll     @OUT BIN\*.* @OVERWRITE
  206.         @File qtw\qthndlr.dll    @OUT BIN\*.* @OVERWRITE
  207.         @File qtw\qtim.dll    @OUT BIN\*.* @OVERWRITE
  208.         @File qtw\qtimcmgr.dll    @OUT BIN\*.* @OVERWRITE
  209.         @File qtw\qtole.dll    @OUT BIN\*.* @OVERWRITE
  210.         @File qtw\qtvhdw.dll    @OUT BIN\*.* @OVERWRITE
  211.         @File qtw\viewenu.dll    @OUT BIN\*.* @OVERWRITE
  212.         @File qtw\mciqtw.drv    @OUT BIN\*.* @OVERWRITE
  213.         @File qtw\player.exe    @OUT BIN\*.* @OVERWRITE
  214.         @File qtw\qtnotify.exe    @OUT BIN\*.* @OVERWRITE
  215.         @File qtw\viewer.exe    @OUT BIN\*.* @OVERWRITE
  216.         @File qtw\navg.qtc    @OUT BIN\*.* @OVERWRITE
  217.         @File qtw\qcmc.qtc    @OUT BIN\*.* @OVERWRITE
  218.         @File qtw\qtcvid.qtc    @OUT BIN\*.* @OVERWRITE
  219.         @File qtw\qtjpeg.qtc    @OUT BIN\*.* @OVERWRITE
  220.         @File qtw\qtmsvc.qtc    @OUT BIN\*.* @OVERWRITE
  221.         @File qtw\qtraw.qtc    @OUT BIN\*.* @OVERWRITE
  222.         @File qtw\qtrle.qtc    @OUT BIN\*.* @OVERWRITE
  223.         @File qtw\qtrpza.qtc    @OUT BIN\*.* @OVERWRITE
  224.         @File qtw\qtrt21.qtc    @OUT BIN\*.* @OVERWRITE
  225.         @File qtw\qtsmc.qtc    @OUT BIN\*.* @OVERWRITE
  226.         @File qtw\qtyvu9.qtc    @OUT BIN\*.* @OVERWRITE
  227.  
  228.     
  229.     @EndIf    // Option 1002
  230. @EndDisk
  231.  
  232.  
  233. /*
  234.  *    The following lines will be placed into any pre-existing AUTOEXEC.BAT
  235.  *    file on the boot disk in the boot drive.  If no AUTOEXEC.BAT file 
  236.  *    already exists, then one will be created.
  237.  *
  238.  *    Each of the two AUTOEXEC.BAT related commands, @Path and @Verbatim,
  239.  *    is aware of the structure of an AUTOEXEC.BAT file.
  240.  *
  241.  *    The @Path command examines each node of any existing PATH= commands
  242.  *    (or its synonym SET PATH=) and places each of the nodes specified
  243.  *    in the @Path command of the INSTALL.DAT file only if the node
  244.  *    does not already exist on the PATH= search list of the AUTOEXEC.BAT
  245.  *    file.
  246.  *
  247.  *    The @Verbatim command instructs INSTALL to place the quoted string
  248.  *    into the AUTOEXEC.BAT file, if the string is not already there.
  249.  */
  250. @if(1002 [! @option) @qtw=0 @Else @qtw = 1500  
  251.  
  252.     @SetAutoexec
  253.         @ASKOverwrite
  254.         @Path = "@OutDrive:@Subdir\\BIN"
  255.         
  256.     @EndAutoexec
  257. @EndIf //if group not selected zero out
  258.  
  259. @Finish
  260. @If(@BackgroundMode(3,@Blue,@Black))@EndIf
  261. @Cls
  262. /*
  263.     The following command is used to create the INSTALL group and
  264.     add the INSTALL item to the Windows Program Manager.
  265. */
  266.  
  267. @ProgramManager("[CreateGroup(From Baku)][AddItem(@WindowsDrive:\\@WindowsDir\\Manual.txt, Manual)][AddItem(@StartupDrive:\\@StartupDir\\QTW\\player.exe, QT Player)][ShowGroup(From Baku, 2)]")
  268.  
  269.  
  270. @Cls
  271.  
  272. @Name is finished installing.  Thank you for your purchase.
  273.  
  274.  
  275. @Pause
  276. @If(@BackgroundMode(3,@Blue,@Black))@EndIf
  277.  
  278. @ChDrive (@OutDrive)
  279. @ChDir ("@SubDir")
  280. @EndFinish
  281.  
  282. // end-of-file
  283.